package com.cskaoyan.controller;

import com.cskaoyan.bean.BaseRespVo;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * @author stone
 * @date 2022/07/09 10:30
 */
@Controller
public class HelloController {

    @RequestMapping("/hello")
    @ResponseBody // json
    public BaseRespVo hello() {
        BaseRespVo baseRespVo = new BaseRespVo();
        baseRespVo.setData("hello springmvc");
        baseRespVo.setMsg("success");
        baseRespVo.setStatus(200);
        return baseRespVo;
    }
}
